package com.blog.biz;

import com.blog.entity.User;

import javax.servlet.http.HttpSession;
import java.io.Serializable;

/**
 * Created with IntelliJ IDEA.
 * Author:  Wu Yujie
 * Email:  coffee377@dingtalk.com
 * Time:  2017/02/16 00:25
 */
public interface UserBiz {

    int USER_NOT_EXIST = 10000;//用户不存在
    int USER_IS_EXIST = 10000;//用户不存在
    int USER_PASSWORD_ERROR = 10001;//密码不匹配
    int LOGIN_SUCCESS = 10002;//成功的状态码

    boolean existUser(String userName);

    User login(String userName, String password);

    void logout(HttpSession session);

    Serializable register(User user);
}
